<?php
/**
 * 配置
 * Created by PhpStorm.
 * User: yui
 * Date: 2017/4/18
 * Time: 21:47
 */

namespace backend\controllers;

use common\controllers\BackendCommonCtrl;
use common\services\ConfigSve;

class ConfigController extends BackendCommonCtrl
{
    public function actionEdit()
    {
        $request = \Yii::$app->request;
        if ($request->isPost) {
            $ConfigSve = new ConfigSve();
            $rs = $ConfigSve->update($request->post());
            return $this->asJson($rs);
        } else {
            return $this->render('edit');
        }
    }
}